﻿@model IEnumerable<KRM.Core.vParagonBoxedItem>
@{
    ViewBag.Title = "ExportBoxedItems";
    Layout = "~/Views/Shared/_PopupLayout.cshtml";
}
<script src="/js/tabletocsv.js"></script>
<div style="padding: 10px">
    <form action="/load/exportboxeditems">
        <div class="row-fluid">
            <div class="span3">
                <button class="btn btn-primary" type="submit"><i class="icon-refresh"></i>Refresh List</button>
                <button class="btn btn-info w90" type="button" onclick="ExportCSVWithHead($('.tbboxeditems'), 'Table.csv', $('.theadboxeditems'))">Export</button>
            </div>
            <div class="span3 text-right">Booked in delivery date</div>
            <div class="span2">
                <select name="booked" class="input-block-level">
                    <option value="0">All</option>
                    <option value="1">Yes</option>
                    <option value="2">No</option>
                </select>
            </div>
            <div class="span1">Type</div>
            <div class="span2">
                <select name="booked" class="input-block-level">
                    <option value="All">All</option>
                    <option value="IsBoxed">IsBoxed</option>
                    <option value="Log Cabin Hiab">Log Cabin Hiab</option>
                    <option value="Log Cabin Van">Log Cabin Van</option>
                    <option value="Scotland">Scotland</option>
                    <option value="South West">South West</option>
                    <option value="South East">South East</option>
                    <option value="South Coast">South Coast</option>
                    <option value="South Wales">South Wales</option>
                    <option value="North West">North West</option>
                    <option value="West Wales">West Wales</option>
                    <option value="Other">Other</option>
                </select>
            </div>
        </div>
    </form> 
    Showing @Model.Count() items
    <table class="table table-bordered table-fix tbboxeditems" data-height="200">
        <thead class="theadboxeditems">
            <tr>
                <th>DatePlaced</th>
                <th>DeliveryDate</th>
                <th>Postcode</th>
                <th>OrderNumber</th>
                <th>OrderDescription</th>
                <th>SpecialInstructions</th>
                <th>Weight</th>
                <th>Volume</th>
                <th>Items</th>
                <th>Type</th>
                <th>Name</th>
                <th>Address</th>
                <th>VariableVisitTime</th>
                <th>OrderItemID</th>
                <th>CarrierName</th>
                <th>ProdOptionID</th>
                <th>VehicleCode</th>
            </tr>
        </thead>
        <tbody>
            @foreach (var item in Model)
            {
                <tr>
                    <td>@item.DatePlaced</td>
                    <td>@item.DeliveryDate</td>
                    <td>@item.Postcode</td>
                    <td>@item.SpecialInstructions</td>
                    <td>@item.OrderNumber</td>
                    <td>@item.OrderDescription</td>
                    <td>@item.Weight</td>
                    <td>@item.Volume</td>
                    <td>@item.Items</td>
                    <td>@item.Type</td>
                    <td>@item.Name</td>
                    <td>@item.Address</td>
                    <td>@item.VariableVisitTime</td>
                    <td>@item.OrderItemID</td>
                    <td>@item.carrierName</td>
                    <td>@item.ProdOptionID</td>
                    <td>@item.VehicleCode</td>
                </tr>
            }
        </tbody>
    </table>
</div>
